<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:f="http://xmlns.jcp.org/jsf/core"
      xmlns:p="http://primefaces.org/ui">

<f:view contentType="text/html;charset=UTF-8" encoding="UTF-8">
    <h:head>

    </h:head>

    <h:body>

        <h:form id="form">
            <p:messages id="msgs" showDetail="true">
                <p:autoUpdate />
            </p:messages>

            <p:dataTable id="datatable" value="#{dataTable036.progLanguages}" var="lang"
                         selection="#{dataTable036.selectedProgLanguage}" rowKey="#{lang.id}"
                         paginator="true" rows="4"
                         multiViewState="true">
                <p:ajax event="rowSelect" listener="#{dataTable036.onRowSelect}" />

                <p:column headerText="ID" sortBy="#{lang.id}">
                    <h:outputText value="#{lang.id}"/>
                </p:column>

                <p:column headerText="Name">
                    <h:outputText value="#{lang.name}"/>
                </p:column>

                <p:column headerText="First appeared">
                    <h:outputText value="#{lang.firstAppeared}"/>
                </p:column>
            </p:dataTable>

            <p:commandButton id="buttonClearTableState" value="clear table state" update="@form" action="#{dataTable036.clearTableState()}"/>
        </h:form>

    </h:body>
</f:view>

</html>
